var ListController = (function () {
    function ListController($scope) {
        var _this = this;
        this.$scope = $scope;
        /**
         * 分页
         */
        this.paginationChanged = function (newPage, pageSize) {
            _this.paginationOptions.skipSize = newPage * pageSize - pageSize;
            _this.paginationOptions.pageSize = pageSize;
            _this.paginationOptions.currentPage = newPage;
            _this.loadData(_this.queryTerms, _this.paginationOptions.skipSize, _this.paginationOptions.pageSize);
        };
        /**
         * 查询
         */
        this.query = function () {
            _this.$scope.querying = true;
            _this.queryTerms = _this.$scope.queryTerms;
            _this.loadData(_this.queryTerms, 0, _this.paginationOptions.pageSize);
        };
    }
    /**
     * 初始化
     */
    ListController.prototype.init = function () {
        this.$scope.querying = false;
        this.$scope.queryFunc = this.query;
        this.paginationOptions = {
            skipSize: 0,
            pageSize: 10,
            currentPage: 1
        };
    };
    return ListController;
}());
/**
 * ------------------枚举部分
 */
/**
 * 专员类型
 */
var CommissionerType;
(function (CommissionerType) {
    /**
     * 缺省值
     */
    CommissionerType[CommissionerType["None"] = 0] = "None";
    /**
     * 计划专员
     */
    CommissionerType[CommissionerType["Plan"] = 1] = "Plan";
    /**
     * 调度专员
     */
    CommissionerType[CommissionerType["Dispatch"] = 2] = "Dispatch";
    /**
     * 调度经理
     */
    CommissionerType[CommissionerType["DispatchManager"] = 3] = "DispatchManager";
    /**
     * 客服专员
     */
    CommissionerType[CommissionerType["CustomerService"] = 4] = "CustomerService";
    /**
     * 商务专员
     */
    CommissionerType[CommissionerType["BusinessAffairs"] = 5] = "BusinessAffairs";
    /**
     * 结算专员
     */
    CommissionerType[CommissionerType["Settler"] = 6] = "Settler";
    /**
     * 独立专员
     */
    CommissionerType[CommissionerType["Independent"] = 7] = "Independent";
    /**
     * 客服经理
     */
    CommissionerType[CommissionerType["CustomerManager"] = 8] = "CustomerManager";
})(CommissionerType || (CommissionerType = {}));
